package com.qzsl.platform.rest;


import com.qzsl.platform.service.IDataSourceService;
import com.tac.base.model.PageQuery;
import com.tac.base.model.SimpleMessage;
import com.tac.base.model.SimplePage;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author xx
 * @since 2023-11-24
 */
@RestController
@RequestMapping("/dataSource")
public class DataSourceController {


    @Resource
    IDataSourceService  dataSourceService;

    /**
     * 分页查询数据源
     *
     * @param pageQuery
     * @return
     */
    @GetMapping("/page")
    public SimpleMessage page(PageQuery pageQuery) {
        SimplePage page = dataSourceService.page(pageQuery);
        return SimpleMessage.info(page);
    }

}

